<!doctype html>



  


<html class="theme-next mist use-motion" lang="zh-Hans">
<head>
  <meta charset="UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"/>






<meta http-equiv="Cache-Control" content="no-transform" />
<meta http-equiv="Cache-Control" content="no-siteapp" />















  
  
  <link href="/lib/fancybox/source/jquery.fancybox.css?v=2.1.5" rel="stylesheet" type="text/css" />




  
  
  
  

  
    
    
  

  

  

  

  

  
    
    
    <link href="//fonts.googleapis.com/css?family=Lato:300,300italic,400,400italic,700,700italic&subset=latin,latin-ext" rel="stylesheet" type="text/css">
  






<link href="/lib/font-awesome/css/font-awesome.min.css?v=4.6.2" rel="stylesheet" type="text/css" />

<link href="/css/main.css?v=5.1.1" rel="stylesheet" type="text/css" />


  <meta name="keywords" content="iOS,安全攻防," />





  <link rel="alternate" href="/atom.xml" title="Bingo's Blog" type="application/atom+xml" />




  <link rel="shortcut icon" type="image/x-icon" href="/favicon.ico?v=5.1.1" />






<meta name="description" content="前言为了越狱，真是操碎了心。不过，这确实是一段有意义的回忆，若干年后，当 iPhone 出到十几代的时候，回头再来看看，肯定会很有感触。">
<meta name="keywords" content="iOS,安全攻防">
<meta property="og:type" content="article">
<meta property="og:title" content="iOS10.2 非完美越狱">
<meta property="og:url" content="https://bingozb.github.io/18.html">
<meta property="og:site_name" content="Bingo's Blog">
<meta property="og:description" content="前言为了越狱，真是操碎了心。不过，这确实是一段有意义的回忆，若干年后，当 iPhone 出到十几代的时候，回头再来看看，肯定会很有感触。">
<meta property="og:image" content="https://bingozb.github.io/images/blog/18/impactor.png">
<meta property="og:image" content="https://bingozb.github.io/images/blog/18/password.png">
<meta property="og:image" content="https://bingozb.github.io/images/blog/18/error.png">
<meta property="og:image" content="https://bingozb.github.io/images/blog/18/appleid_password.png">
<meta property="og:image" content="https://bingozb.github.io/images/blog/18/warning.png">
<meta property="og:image" content="https://bingozb.github.io/images/blog/18/home.png">
<meta property="og:image" content="https://bingozb.github.io/images/blog/18/cydia.png">
<meta property="og:image" content="https://bingozb.github.io/images/blog/18/iTools.png">
<meta property="og:image" content="https://bingozb.github.io/images/blog/18/cydia1.png">
<meta property="og:image" content="https://bingozb.github.io/images/blog/18/cydia2.png">
<meta property="og:image" content="https://bingozb.github.io/images/blog/18/cydia3.png">
<meta property="og:image" content="https://bingozb.github.io/images/blog/18/cydia4.png">
<meta property="og:image" content="https://bingozb.github.io/images/blog/18/cydia5.png">
<meta property="og:image" content="https://bingozb.github.io/images/blog/18/cydia6.png">
<meta property="og:image" content="https://bingozb.github.io/images/blog/18/iTools1.png">
<meta property="og:updated_time" content="2017-09-22T17:30:21.000Z">
<meta name="twitter:card" content="summary">
<meta name="twitter:title" content="iOS10.2 非完美越狱">
<meta name="twitter:description" content="前言为了越狱，真是操碎了心。不过，这确实是一段有意义的回忆，若干年后，当 iPhone 出到十几代的时候，回头再来看看，肯定会很有感触。">
<meta name="twitter:image" content="https://bingozb.github.io/images/blog/18/impactor.png">



<script type="text/javascript" id="hexo.configurations">
  var NexT = window.NexT || {};
  var CONFIG = {
    root: '/',
    scheme: 'Mist',
    sidebar: {"position":"left","display":"post","offset":12,"offset_float":0,"b2t":false,"scrollpercent":false},
    fancybox: true,
    motion: true,
    duoshuo: {
      userId: 'undefined',
      author: '博主'
    },
    algolia: {
      applicationID: 'JE30EVH7NI',
      apiKey: '862bb3deb9a3166ed99de0be6527f59c',
      indexName: 'blog',
      hits: {"per_page":10},
      labels: {"input_placeholder":"输入关键词进行搜索","hits_empty":"找不到关于「 ${query} 」的文章","hits_stats":"共找到 ${hits} 篇文章，花了 ${time} ms"}
    }
  };
</script>



  <link rel="canonical" href="https://bingozb.github.io/18.html"/>





  <title>iOS10.2 非完美越狱 | Bingo's Blog</title>
</head>

<body itemscope itemtype="http://schema.org/WebPage" lang="zh-Hans">

  





  <script type="text/javascript">
    var _hmt = _hmt || [];
    (function() {
      var hm = document.createElement("script");
      hm.src = "https://hm.baidu.com/hm.js?c8a59b9753bce3ec58f81c89e2acce96";
      var s = document.getElementsByTagName("script")[0];
      s.parentNode.insertBefore(hm, s);
    })();
  </script>










  
  
    
  

  <div class="container sidebar-position-left page-post-detail ">
    <div class="headband"></div>

    <header id="header" class="header" itemscope itemtype="http://schema.org/WPHeader">
      <div class="header-inner"><div class="site-brand-wrapper">
  <div class="site-meta ">
    

    <div class="custom-logo-site-title">
      <a href="/"  class="brand" rel="start">
        <span class="logo-line-before"><i></i></span>
        <span class="site-title">Bingo's Blog</span>
        <span class="logo-line-after"><i></i></span>
      </a>
    </div>
      
        <p class="site-subtitle">Stay Hungry, Stay Foolish.</p>
      
  </div>

  <div class="site-nav-toggle">
    <button>
      <span class="btn-bar"></span>
      <span class="btn-bar"></span>
      <span class="btn-bar"></span>
    </button>
  </div>
</div>

<nav class="site-nav">
  

  
    <ul id="menu" class="menu">
      
        
        <li class="menu-item menu-item-home">
          <a href="/" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-home"></i> <br />
            
            首页
          </a>
        </li>
      
        
        <li class="menu-item menu-item-categories">
          <a href="/categories" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-th"></i> <br />
            
            分类
          </a>
        </li>
      
        
        <li class="menu-item menu-item-tags">
          <a href="/tags" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-tags"></i> <br />
            
            标签
          </a>
        </li>
      
        
        <li class="menu-item menu-item-archives">
          <a href="/archives" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-archive"></i> <br />
            
            归档
          </a>
        </li>
      
        
        <li class="menu-item menu-item-about">
          <a href="/about" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-user"></i> <br />
            
            关于
          </a>
        </li>
      

      
        <li class="menu-item menu-item-search">
          
            <a href="javascript:;" class="popup-trigger">
          
            
              <i class="menu-item-icon fa fa-search fa-fw"></i> <br />
            
            搜索
          </a>
        </li>
      
    </ul>
  

  
    <div class="site-search">
      
  <div class="popup search-popup local-search-popup">
  <div class="local-search-header clearfix">
    <span class="search-icon">
      <i class="fa fa-search"></i>
    </span>
    <span class="popup-btn-close">
      <i class="fa fa-times-circle"></i>
    </span>
    <div class="local-search-input-wrapper">
      <input autocapitalize="off" autocomplete="off" autocorrect="off"
             placeholder="搜索..." spellcheck="false"
             type="text" id="local-search-input">
    </div>
  </div>
  <div id="local-search-result"></div>
</div>



    </div>
  
</nav>



 </div>
    </header>

    <main id="main" class="main">
      <div class="main-inner">
        <div class="content-wrap">
          <div id="content" class="content">
            

  <div id="posts" class="posts-expand">
    

  

  
  
  

  <article class="post post-type-normal " itemscope itemtype="http://schema.org/Article">
    <link itemprop="mainEntityOfPage" href="https://bingozb.github.io/18.html">

    <span hidden itemprop="author" itemscope itemtype="http://schema.org/Person">
      <meta itemprop="name" content="Bingo">
      <meta itemprop="description" content="">
      <meta itemprop="image" content="/images/avatar.jpg">
    </span>

    <span hidden itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
      <meta itemprop="name" content="Bingo's Blog">
    </span>

    
      <header class="post-header">

        
        
          <h1 class="post-title" itemprop="name headline">
            
            
              
                iOS10.2 非完美越狱
              
            
          </h1>
        

        <div class="post-meta">
          <span class="post-time">
            
              <span class="post-meta-item-icon">
                <i class="fa fa-calendar-o"></i>
              </span>
              
                <span class="post-meta-item-text">发表于</span>
              
              <time title="创建于" itemprop="dateCreated datePublished" datetime="2017-02-19T21:19:49+08:00">
                2017-02-19
              </time>
            

            

            
          </span>

          
            <span class="post-category" >
            
              <span class="post-meta-divider">|</span>
            
              <span class="post-meta-item-icon">
                <i class="fa fa-folder-o"></i>
              </span>
              
                <span class="post-meta-item-text">分类于</span>
              
              
                <span itemprop="about" itemscope itemtype="http://schema.org/Thing">
                  <a href="/categories/战斗笔记/" itemprop="url" rel="index">
                    <span itemprop="name">战斗笔记</span>
                  </a>
                </span>

                
                
              
            </span>
          

          
            
              <span class="post-comments-count">
              <span class="post-meta-divider">|</span>
              <span class="post-meta-item-icon">
                <i class="fa fa-comment-o"></i>
              </span>
              
                <a href="/18.html#SOHUCS" itemprop="discussionUrl">
                  <span id="changyan_count_unit" class="post-comments-count hc-comment-count" data-xid="18.html" itemprop="commentsCount"></span>
                </a>
              
            
          

          
          
             <span id="/18.html" class="leancloud_visitors" data-flag-title="iOS10.2 非完美越狱">
               <span class="post-meta-divider">|</span>
               <span class="post-meta-item-icon">
                 <i class="fa fa-eye"></i>
               </span>
               
                 <span class="post-meta-item-text">阅读次数 </span>
               
                 <span class="leancloud-visitors-count"></span>
             </span>
          

          

          

          

        </div>
      </header>
    

    <div class="post-body" itemprop="articleBody">

      
      

      
        <h2 id="前言"><a href="#前言" class="headerlink" title="前言"></a>前言</h2><p>为了越狱，真是操碎了心。不过，这确实是一段有意义的回忆，若干年后，当 iPhone 出到十几代的时候，回头再来看看，肯定会很有感触。</p>
<a id="more"></a>
<h2 id="回想当年"><a href="#回想当年" class="headerlink" title="回想当年"></a>回想当年</h2><p>我上一次玩越狱大概是在2012年，那时候 iPhone 4s 刚刚面世，我就买了一部。对于一个高中生，3750元简直是天价。真果粉的我，靠玩游戏赚钱，每天大概一小时收入20块，（每天也就一小时），积累了数月后，带着3700元去到手机店，差50元是跟我爸借的。</p>
<p>从那一刻开始，我就定下了人生的一个原则：作为一个真果粉，苹果可以买买买，但要靠自己，不能向家里人要钱。 我现在已经拥有六件苹果设备，无一例外都遵循这个原则。</p>
<p>那时候我身边的朋友们大部分是买 iPhone 4，iOS 系统是 5.0 左右的版本，有些朋友特别喜欢 iOS 5.5。我买 4s 的时候内置了 6.1.0，后来我升到了 6.1.2，是 iOS 6 系列最后一个能越狱的版本。我记得我姐后来也买了一部，那时候出厂已经是 6.1.3，不能越狱了。</p>
<p>想当年，改主题、改状态栏，把运营商如“中国移动”改为自定义的文字，图案等，电池显示样式也可以随机改、改锁屏页，充电时候屏幕中间的绿色电池可以改成其他样式，“滑动来解锁”的字可以改得闪闪发光，可以在中文语言状态下把这些字改成自定义的英文，向右滑动解锁可以改成向上；各种插件，自定义手势，屏幕左划一下打开QQ，屏幕右划一下打开电话，屏幕上划打开后台管理等等。那时候玩越狱，完全就可以把 iPhone 当安卓来玩，完全自定义，没有办不到的事。</p>
<p>当初越狱最早的初衷只是为了一个九宫格输入法，相信很多人都跟我一样。进了门之后才发现是一个新世界，自由的世界，甚至天堂。不需要 Apple ID，应用可以随便下，App Store 里面收费的应用或者游戏都可以免费下。那时候，大部分人买手机就会选择越狱，那以及是主流用户习惯。后来，iOS 7 出来的时候，自带的输入法已经支持九宫格了，这让一大波越狱用户“改邪归正”，“越狱还有什么用”之类的党派之争也随之而来，当然，对这种事情我们当然是保留自己的看法就好。所以，我坚持不升级，一直到 iPhone 6 出现，带来了 iOS 9 系列。从未体验过 iOS 7 的我，跳过了 iOS 7 和 iOS 8，直接把我的 iPhone 4s 升级到了 iOS 9.0。</p>
<p>那时的我，是多么固执！越过了两个大版本的系统，坚持不升级。某一天，心血来潮，在监狱外面呆久了，突然想回到牢里去，于是我就升级了。就是这么一升，回不去了！苹果关闭了低版本的固件验证，再也刷不回低版本了，我的 iOS 6 啊！那可是最流畅的系统版本，没有之一。看那夕阳下的奔跑，那是我逝去的青春~</p>
<p>所以，最终的结局就是我的4s变得卡得要命，刷不回去，废了。次年9月苹果发布 iPhone 6s，我在双十一用奖学金买了一部 iPhone 6s plus，64G 土豪金，当时官网价格是 7188，趁着双十一活动 6588 拿下了它。</p>
<h2 id="现在"><a href="#现在" class="headerlink" title="现在"></a>现在</h2><p>为什么要说上面的经历呢，除了留作我个人回忆，还有就是因为那个时候越狱玩的东西，跟我现在要做的事情息息相关。也正是那时候玩过，现在的理解才会跟别人有差异。现在大部分人都不懂越狱是什么东西，只有一个模糊的概念，毕竟近些年已经渐渐没听到这个词了。</p>
<p>其实，越狱，简单地讲，就是 iOS 系统被黑了，被破解了。</p>
<p>高手在民间，从太极到盘古，再到如今的卢卡斯，都在打苹果的脸。连苹果自己都无法阻止被黑，那么上架到 app Store 上面的 app 就一定安全吗？我看不见得吧，即便苹果帮我们的 ipa 穿上了一层战衣，但还是挡不住有心人。敲壳、反编译等等逆向工程的我会慢慢写文章来记录。</p>
<p>先要知道如何攻击，才能知道如何防守。而这一切，都跟越狱有关，比如许多操作需要越狱设备开启 SSH 通道，电脑连上越狱设备后通过终端命令行运行objc代码等等。那么就将越狱作为安全攻防的开端吧。</p>
<p>废话不多说，马上开始越狱吧。</p>
<h2 id="越狱"><a href="#越狱" class="headerlink" title="越狱"></a>越狱</h2><h3 id="下载安装越狱工具"><a href="#下载安装越狱工具" class="headerlink" title="下载安装越狱工具"></a>下载安装越狱工具</h3><ul>
<li>Cydia Impactor<ul>
<li><a href="https://cdn.bingo.ren/app/impactor_0.9.38.dmg" target="_blank" rel="external">Cydia Impactor for Mac</a></li>
<li><a href="https://cdn.bingo.ren/app/Impactor_0.9.38.zip" target="_blank" rel="external">Cydia Impactor for Windows</a></li>
</ul>
</li>
<li><a href="https://cdn.bingo.ren/app/yalu102_beta7.ipa" target="_blank" rel="external">yalu102_beta7.ipa</a></li>
</ul>
<h3 id="加载-ipa"><a href="#加载-ipa" class="headerlink" title="加载 ipa"></a>加载 ipa</h3><p>以 mac 为例，手机连上电脑后，软件会读取到手机信息，把 yalu102_beta7.ipa 拖入软件中。</p>
<p><img src="images/blog/18/impactor.png" alt="impactor"></p>
<h3 id="输入-Apple-ID-和-密码"><a href="#输入-Apple-ID-和-密码" class="headerlink" title="输入 Apple ID 和 密码"></a>输入 Apple ID 和 密码</h3><p>输入 apple ID，然后输入密码</p>
<p><img src="images/blog/18/password.png" alt="password"></p>
<p>注意，这个密码可以是 Apple ID 的密码，但不能开启双重验证，否则会报错。</p>
<p><img src="images/blog/18/error.png" alt="error"></p>
<p>如果不想关闭双重验证，为了安全着想确实不应该关闭，那么可以去 <a href="https://appleid.apple.com/account/manage" target="_blank" rel="external">苹果ID官网</a> 安全 那里申请 App 专用密码。</p>
<p><img src="images/blog/18/appleid_password.png" alt="appleid_appPwd"></p>
<p>然后重新按照前面的步骤，到输入密码那一步的时候，输入刚刚生成的密码，注意大小写。</p>
<p>接着会出现一个警告，如果看到这个警告基本就没什么问题了。</p>
<p><img src="images/blog/18/warning.png" alt="warning"></p>
<p>警告的意思是，接下来会废除并替换掉这个账号所有的证书，也就是以前的证书会全部失效，最直接的结果就是原本 iCloud 登录了这个账号，会被要求重新输入密码重新登录。其它的证书暂时没发现有什么影响。</p>
<h3 id="安装成功"><a href="#安装成功" class="headerlink" title="安装成功"></a>安装成功</h3><p>点击 OK 后，就会一直自动执行到安装 ipa 成功。其中包括了用刚刚输入的 Apple ID 对 ipa 进行签名，有效期为7天。然后安装 ipa 到所连接的手机中，最后看到 complete 的时候就安装完成了。这个时候看手机，可以看到有一个 app 名字为 yalu102，icon 是灰色的金三胖。</p>
<h3 id="授权验证"><a href="#授权验证" class="headerlink" title="授权验证"></a>授权验证</h3><p>这个时候还不能打开，需要先信任开发者。点击设置 - 通用 - 设备管理，就可以看到开发者应用下面有一个刚刚输入的 Apple ID，点击进入详情界面，再点击验证即可。</p>
<h3 id="开始越狱"><a href="#开始越狱" class="headerlink" title="开始越狱"></a>开始越狱</h3><p>验证成功后，打开 yalu102，点击屏幕中的 go，即可开始越狱。完成的时候会自动重启，重启后 Cydia 就出来了，越狱完成。</p>
<h3 id="完成越狱"><a href="#完成越狱" class="headerlink" title="完成越狱"></a>完成越狱</h3><p>由于操作都很简单，直接截最终的效果：</p>
<p><img src="images/blog/18/home.png" width="300">&nbsp;<br><img src="images/blog/18/cydia.png" width="300"></p>
<h2 id="补充"><a href="#补充" class="headerlink" title="补充"></a>补充</h2><p>越狱后需要安装一个补丁，否则无法访问系统文件，如果你没有这个需求，那我就很好奇你干嘛要越狱了。</p>
<p>cydia 之父发布了支持 iOS 7.1.2 系统的 Afc 补丁，取名为“Apple File Conduit “2” ”，与 afc2add 服务补丁功能一样，都是为了解决 iOS 7.x 越狱后无法访问系统文件（越狱）的问题，大家可以直接在PP助手源上上安装最新的 Afc 补丁</p>
<h3 id="打补丁前的文件系统"><a href="#打补丁前的文件系统" class="headerlink" title="打补丁前的文件系统"></a>打补丁前的文件系统</h3><p>电脑上选择一款管理软件，比如PP助手、iTools等。我选择 iTools，因为我的虚拟机打开PP助手的时候总是提示我的文档的权限有问题，可能是跟虚拟机 Parallels Desktop 不兼容吧。</p>
<p>先看看安装补丁前的文件目录，文件系统下面只有用户系统。</p>
<p><img src="images/blog/18/iTools.png" alt="iTools"></p>
<h3 id="开始打补丁"><a href="#开始打补丁" class="headerlink" title="开始打补丁"></a>开始打补丁</h3><p>首先打开手机上的 Cydia，选择底部的软件源，点击右上角的编辑，然后添加PP助手源。</p>
<p><img src="images/blog/18/cydia1.png" width="300">&nbsp;<br><img src="images/blog/18/cydia2.png" width="300"></p>
<p>添加完毕后在软件源中找到“PP助手源”，选择“全部软件包”，然后选择 Apple File Conduit “2” 。</p>
<p><img src="images/blog/18/cydia3.png" width="300">&nbsp;<br><img src="images/blog/18/cydia4.png" width="300"></p>
<p>点击进入详情，并点击右上角的安装即可完成。</p>
<p><img src="images/blog/18/cydia5.png" width="300">&nbsp;<br><img src="images/blog/18/cydia6.png" width="300"></p>
<h3 id="打补丁后的文件系统"><a href="#打补丁后的文件系统" class="headerlink" title="打补丁后的文件系统"></a>打补丁后的文件系统</h3><p>最后重新打开iTools，看看打完补丁的文件系统，就可以看到越狱系统了。</p>
<p><img src="images/blog/18/iTools1.png" alt="iTools"></p>
<h2 id="后话"><a href="#后话" class="headerlink" title="后话"></a>后话</h2><p>至此，一部64位的iPhone，iOS 10.2 就越狱成功了，也可以访问到系统文件了。但是，正如标题所说，这是非完美越狱。也就是说，重启手机后，打开 Cydia 就闪退了，需要打开 yalu102 重新越狱。不过还好，过程还是挺快的。</p>
<h2 id="参考"><a href="#参考" class="headerlink" title="参考"></a>参考</h2><p><a href="http://bbs.25pp.com/thread-225764-1-1.html" target="_blank" rel="external">Apple File Conduit”2”补丁安装教程</a></p>

      
    </div>

    <div>
      
        

      
    </div>

    <div>
      
        

      
    </div>

    <div>
      
        
  <ul class="post-copyright">
    <li class="post-copyright-author">
      <strong>本文作者：</strong>
      Bingo
    </li>
    <li class="post-copyright-link">
      <strong>本文链接：</strong>
      <a href="https://bingozb.github.io/18.html" title="iOS10.2 非完美越狱">https://bingozb.github.io/18.html</a>
    </li>
    <li class="post-copyright-license">
      <strong>版权声明： </strong>
      本博客所有文章除特别声明外，均采用 MIT 许可协议。转载请注明出处！
    </li>
  </ul>


      
    </div>

    <footer class="post-footer">
      
        <div class="post-tags">
          
            <a href="/tags/iOS/" rel="tag"># iOS</a>
          
            <a href="/tags/安全攻防/" rel="tag"># 安全攻防</a>
          
        </div>
      

      
        
      

      
        <div class="post-nav">
          <div class="post-nav-next post-nav-item">
            
              <a href="/19.html" rel="next" title="屏蔽iPhone自动下载更新（上）">
                <i class="fa fa-chevron-left"></i> 屏蔽iPhone自动下载更新（上）
              </a>
            
          </div>

          <span class="post-nav-divider"></span>

          <div class="post-nav-prev post-nav-item">
            
              <a href="/17.html" rel="prev" title="Objective-C 代码混淆">
                Objective-C 代码混淆 <i class="fa fa-chevron-right"></i>
              </a>
            
          </div>
        </div>
      

      
      
    </footer>
  </article>



    <div class="post-spread">
      
    </div>
  </div>


          </div>
          


          
  <div class="comments" id="comments">
    
      <div id="SOHUCS"></div>
    
  </div>


        </div>
        
          
  
  <div class="sidebar-toggle">
    <div class="sidebar-toggle-line-wrap">
      <span class="sidebar-toggle-line sidebar-toggle-line-first"></span>
      <span class="sidebar-toggle-line sidebar-toggle-line-middle"></span>
      <span class="sidebar-toggle-line sidebar-toggle-line-last"></span>
    </div>
  </div>

  <aside id="sidebar" class="sidebar">
    <div class="sidebar-inner">

      

      
        <ul class="sidebar-nav motion-element">
          <li class="sidebar-nav-toc sidebar-nav-active" data-target="post-toc-wrap" >
            文章目录
          </li>
          <li class="sidebar-nav-overview" data-target="site-overview">
            站点概览
          </li>
        </ul>
      

      <section class="site-overview sidebar-panel">
        <div class="site-author motion-element" itemprop="author" itemscope itemtype="http://schema.org/Person">
          <img class="site-author-image" itemprop="image"
               src="/images/avatar.jpg"
               alt="Bingo" />
          <p class="site-author-name" itemprop="name">Bingo</p>
           
              <p class="site-description motion-element" itemprop="description">He who hesitates is lost.</p>
          
        </div>
        <nav class="site-state motion-element">

          
            <div class="site-state-item site-state-posts">
              <a href="/archives">
                <span class="site-state-item-count">55</span>
                <span class="site-state-item-name">日志</span>
              </a>
            </div>
          

          
            
            
            <div class="site-state-item site-state-categories">
              <a href="/categories/index.html">
                <span class="site-state-item-count">4</span>
                <span class="site-state-item-name">分类</span>
              </a>
            </div>
          

          
            
            
            <div class="site-state-item site-state-tags">
              <a href="/tags/index.html">
                <span class="site-state-item-count">22</span>
                <span class="site-state-item-name">标签</span>
              </a>
            </div>
          

        </nav>

        
          <div class="feed-link motion-element">
            <a href="/atom.xml" rel="alternate">
              <i class="fa fa-rss"></i>
              RSS
            </a>
          </div>
        

        <div class="links-of-author motion-element">
          
            
              <span class="links-of-author-item">
                <a href="https://github.com/bingozb" target="_blank" title="GitHub">
                  
                    <i class="fa fa-fw fa-github"></i>
                  
                  GitHub
                </a>
              </span>
            
              <span class="links-of-author-item">
                <a href="https://coding.net/u/bingozb" target="_blank" title="Coding">
                  
                    <i class="fa fa-fw fa-git"></i>
                  
                  Coding
                </a>
              </span>
            
              <span class="links-of-author-item">
                <a href="https://twitter.com/bingo_v587" target="_blank" title="Twitter">
                  
                    <i class="fa fa-fw fa-twitter"></i>
                  
                  Twitter
                </a>
              </span>
            
              <span class="links-of-author-item">
                <a href="https://www.facebook.com/profile.php?id=100013406670597" target="_blank" title="Facebook">
                  
                    <i class="fa fa-fw fa-facebook"></i>
                  
                  Facebook
                </a>
              </span>
            
          
        </div>

        
        

        
        

        


      </section>

      
      <!--noindex-->
        <section class="post-toc-wrap motion-element sidebar-panel sidebar-panel-active">
          <div class="post-toc">

            
              
            

            
              <div class="post-toc-content"><ol class="nav"><li class="nav-item nav-level-2"><a class="nav-link" href="#前言"><span class="nav-number">1.</span> <span class="nav-text">前言</span></a></li><li class="nav-item nav-level-2"><a class="nav-link" href="#回想当年"><span class="nav-number">2.</span> <span class="nav-text">回想当年</span></a></li><li class="nav-item nav-level-2"><a class="nav-link" href="#现在"><span class="nav-number">3.</span> <span class="nav-text">现在</span></a></li><li class="nav-item nav-level-2"><a class="nav-link" href="#越狱"><span class="nav-number">4.</span> <span class="nav-text">越狱</span></a><ol class="nav-child"><li class="nav-item nav-level-3"><a class="nav-link" href="#下载安装越狱工具"><span class="nav-number">4.1.</span> <span class="nav-text">下载安装越狱工具</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#加载-ipa"><span class="nav-number">4.2.</span> <span class="nav-text">加载 ipa</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#输入-Apple-ID-和-密码"><span class="nav-number">4.3.</span> <span class="nav-text">输入 Apple ID 和 密码</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#安装成功"><span class="nav-number">4.4.</span> <span class="nav-text">安装成功</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#授权验证"><span class="nav-number">4.5.</span> <span class="nav-text">授权验证</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#开始越狱"><span class="nav-number">4.6.</span> <span class="nav-text">开始越狱</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#完成越狱"><span class="nav-number">4.7.</span> <span class="nav-text">完成越狱</span></a></li></ol></li><li class="nav-item nav-level-2"><a class="nav-link" href="#补充"><span class="nav-number">5.</span> <span class="nav-text">补充</span></a><ol class="nav-child"><li class="nav-item nav-level-3"><a class="nav-link" href="#打补丁前的文件系统"><span class="nav-number">5.1.</span> <span class="nav-text">打补丁前的文件系统</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#开始打补丁"><span class="nav-number">5.2.</span> <span class="nav-text">开始打补丁</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#打补丁后的文件系统"><span class="nav-number">5.3.</span> <span class="nav-text">打补丁后的文件系统</span></a></li></ol></li><li class="nav-item nav-level-2"><a class="nav-link" href="#后话"><span class="nav-number">6.</span> <span class="nav-text">后话</span></a></li><li class="nav-item nav-level-2"><a class="nav-link" href="#参考"><span class="nav-number">7.</span> <span class="nav-text">参考</span></a></li></ol></div>
            

          </div>
        </section>
      <!--/noindex-->
      

      

    </div>
  </aside>


        
      </div>
    </main>

    <footer id="footer" class="footer">
      <div class="footer-inner">
        <div class="copyright" >
  
  Copyright © 
  <span itemprop="copyrightYear">2017
  </span>
  <span class="author" itemprop="copyrightHolder">Bingo
  </span>
  All rights reserved.
</div>
        

        
      </div>
    </footer>

    
      <div class="back-to-top">
        <i class="fa fa-arrow-up"></i>
        
      </div>
    

  </div>

  

<script type="text/javascript">
  if (Object.prototype.toString.call(window.Promise) !== '[object Function]') {
    window.Promise = null;
  }
</script>









  












  
  <script type="text/javascript" src="/lib/jquery/index.js?v=2.1.3"></script>

  
  <script type="text/javascript" src="/lib/fastclick/lib/fastclick.min.js?v=1.0.6"></script>

  
  <script type="text/javascript" src="/lib/jquery_lazyload/jquery.lazyload.js?v=1.9.7"></script>

  
  <script type="text/javascript" src="/lib/velocity/velocity.min.js?v=1.2.1"></script>

  
  <script type="text/javascript" src="/lib/velocity/velocity.ui.min.js?v=1.2.1"></script>

  
  <script type="text/javascript" src="/lib/fancybox/source/jquery.fancybox.pack.js?v=2.1.5"></script>


  


  <script type="text/javascript" src="/js/src/utils.js?v=5.1.1"></script>

  <script type="text/javascript" src="/js/src/motion.js?v=5.1.1"></script>



  
  

  
  <script type="text/javascript" src="/js/src/scrollspy.js?v=5.1.1"></script>
<script type="text/javascript" src="/js/src/post-details.js?v=5.1.1"></script>



  


  <script type="text/javascript" src="/js/src/bootstrap.js?v=5.1.1"></script>



  


  




	





  





  





  




  
    <script type="text/javascript">
    (function(){
      var appid = 'cytcdzpa3';
      var conf = 'c0c6117021d1cea9f11629100efd8446';
      var width = window.innerWidth || document.documentElement.clientWidth;
      if (width < 960) {
      window.document.write('<script id="changyan_mobile_js" charset="utf-8" type="text/javascript" src="https://changyan.sohu.com/upload/mobile/wap-js/changyan_mobile.js?client_id=' + appid + '&conf=' + conf + '"><\/script>'); } else { var loadJs=function(d,a){var c=document.getElementsByTagName("head")[0]||document.head||document.documentElement;var b=document.createElement("script");b.setAttribute("type","text/javascript");b.setAttribute("charset","UTF-8");b.setAttribute("src",d);if(typeof a==="function"){if(window.attachEvent){b.onreadystatechange=function(){var e=b.readyState;if(e==="loaded"||e==="complete"){b.onreadystatechange=null;a()}}}else{b.onload=a}}c.appendChild(b)};loadJs("https://changyan.sohu.com/upload/changyan.js",function(){
        window.changyan.api.config({appid:appid,conf:conf})});
      }
    })();
    </script>
    <script type="text/javascript" src="https://assets.changyan.sohu.com/upload/plugins/plugins.count.js"></script>
  



  

  <script type="text/javascript">
    // Popup Window;
    var isfetched = false;
    var isXml = true;
    // Search DB path;
    var search_path = "search.xml";
    if (search_path.length === 0) {
      search_path = "search.xml";
    } else if (search_path.endsWith("json")) {
      isXml = false;
    }
    var path = "/" + search_path;
    // monitor main search box;

    var onPopupClose = function (e) {
      $('.popup').hide();
      $('#local-search-input').val('');
      $('.search-result-list').remove();
      $('#no-result').remove();
      $(".local-search-pop-overlay").remove();
      $('body').css('overflow', '');
    }

    function proceedsearch() {
      $("body")
        .append('<div class="search-popup-overlay local-search-pop-overlay"></div>')
        .css('overflow', 'hidden');
      $('.search-popup-overlay').click(onPopupClose);
      $('.popup').toggle();
      $('#local-search-input').focus();
    }

    // search function;
    var searchFunc = function(path, search_id, content_id) {
      'use strict';

      // start loading animation
      $("body")
        .append('<div class="search-popup-overlay local-search-pop-overlay">' +
          '<div id="search-loading-icon">' +
          '<i class="fa fa-spinner fa-pulse fa-5x fa-fw"></i>' +
          '</div>' +
          '</div>')
        .css('overflow', 'hidden');
      $("#search-loading-icon").css('margin', '20% auto 0 auto').css('text-align', 'center');

      $.ajax({
        url: path,
        dataType: isXml ? "xml" : "json",
        async: true,
        success: function(res) {
          // get the contents from search data
          isfetched = true;
          $('.popup').detach().appendTo('.header-inner');
          var datas = isXml ? $("entry", res).map(function() {
            return {
              title: $("title", this).text(),
              content: $("content",this).text(),
              url: $("url" , this).text()
            };
          }).get() : res;
          var input = document.getElementById(search_id);
          var resultContent = document.getElementById(content_id);
          var inputEventFunction = function() {
            var searchText = input.value.trim().toLowerCase();
            var keywords = searchText.split(/[\s\-]+/);
            if (keywords.length > 1) {
              keywords.push(searchText);
            }
            var resultItems = [];
            if (searchText.length > 0) {
              // perform local searching
              datas.forEach(function(data) {
                var isMatch = false;
                var hitCount = 0;
                var searchTextCount = 0;
                var title = data.title.trim();
                var titleInLowerCase = title.toLowerCase();
                var content = data.content.trim().replace(/<[^>]+>/g,"");
                var contentInLowerCase = content.toLowerCase();
                var articleUrl = decodeURIComponent(data.url);
                var indexOfTitle = [];
                var indexOfContent = [];
                // only match articles with not empty titles
                if(title != '') {
                  keywords.forEach(function(keyword) {
                    function getIndexByWord(word, text, caseSensitive) {
                      var wordLen = word.length;
                      if (wordLen === 0) {
                        return [];
                      }
                      var startPosition = 0, position = [], index = [];
                      if (!caseSensitive) {
                        text = text.toLowerCase();
                        word = word.toLowerCase();
                      }
                      while ((position = text.indexOf(word, startPosition)) > -1) {
                        index.push({position: position, word: word});
                        startPosition = position + wordLen;
                      }
                      return index;
                    }

                    indexOfTitle = indexOfTitle.concat(getIndexByWord(keyword, titleInLowerCase, false));
                    indexOfContent = indexOfContent.concat(getIndexByWord(keyword, contentInLowerCase, false));
                  });
                  if (indexOfTitle.length > 0 || indexOfContent.length > 0) {
                    isMatch = true;
                    hitCount = indexOfTitle.length + indexOfContent.length;
                  }
                }

                // show search results

                if (isMatch) {
                  // sort index by position of keyword

                  [indexOfTitle, indexOfContent].forEach(function (index) {
                    index.sort(function (itemLeft, itemRight) {
                      if (itemRight.position !== itemLeft.position) {
                        return itemRight.position - itemLeft.position;
                      } else {
                        return itemLeft.word.length - itemRight.word.length;
                      }
                    });
                  });

                  // merge hits into slices

                  function mergeIntoSlice(text, start, end, index) {
                    var item = index[index.length - 1];
                    var position = item.position;
                    var word = item.word;
                    var hits = [];
                    var searchTextCountInSlice = 0;
                    while (position + word.length <= end && index.length != 0) {
                      if (word === searchText) {
                        searchTextCountInSlice++;
                      }
                      hits.push({position: position, length: word.length});
                      var wordEnd = position + word.length;

                      // move to next position of hit

                      index.pop();
                      while (index.length != 0) {
                        item = index[index.length - 1];
                        position = item.position;
                        word = item.word;
                        if (wordEnd > position) {
                          index.pop();
                        } else {
                          break;
                        }
                      }
                    }
                    searchTextCount += searchTextCountInSlice;
                    return {
                      hits: hits,
                      start: start,
                      end: end,
                      searchTextCount: searchTextCountInSlice
                    };
                  }

                  var slicesOfTitle = [];
                  if (indexOfTitle.length != 0) {
                    slicesOfTitle.push(mergeIntoSlice(title, 0, title.length, indexOfTitle));
                  }

                  var slicesOfContent = [];
                  while (indexOfContent.length != 0) {
                    var item = indexOfContent[indexOfContent.length - 1];
                    var position = item.position;
                    var word = item.word;
                    // cut out 100 characters
                    var start = position - 20;
                    var end = position + 80;
                    if(start < 0){
                      start = 0;
                    }
                    if (end < position + word.length) {
                      end = position + word.length;
                    }
                    if(end > content.length){
                      end = content.length;
                    }
                    slicesOfContent.push(mergeIntoSlice(content, start, end, indexOfContent));
                  }

                  // sort slices in content by search text's count and hits' count

                  slicesOfContent.sort(function (sliceLeft, sliceRight) {
                    if (sliceLeft.searchTextCount !== sliceRight.searchTextCount) {
                      return sliceRight.searchTextCount - sliceLeft.searchTextCount;
                    } else if (sliceLeft.hits.length !== sliceRight.hits.length) {
                      return sliceRight.hits.length - sliceLeft.hits.length;
                    } else {
                      return sliceLeft.start - sliceRight.start;
                    }
                  });

                  // select top N slices in content

                  var upperBound = parseInt('-1');
                  if (upperBound >= 0) {
                    slicesOfContent = slicesOfContent.slice(0, upperBound);
                  }

                  // highlight title and content

                  function highlightKeyword(text, slice) {
                    var result = '';
                    var prevEnd = slice.start;
                    slice.hits.forEach(function (hit) {
                      result += text.substring(prevEnd, hit.position);
                      var end = hit.position + hit.length;
                      result += '<b class="search-keyword">' + text.substring(hit.position, end) + '</b>';
                      prevEnd = end;
                    });
                    result += text.substring(prevEnd, slice.end);
                    return result;
                  }

                  var resultItem = '';

                  if (slicesOfTitle.length != 0) {
                    resultItem += "<li><a href='" + articleUrl + "' class='search-result-title'>" + highlightKeyword(title, slicesOfTitle[0]) + "</a>";
                  } else {
                    resultItem += "<li><a href='" + articleUrl + "' class='search-result-title'>" + title + "</a>";
                  }

                  slicesOfContent.forEach(function (slice) {
                    resultItem += "<a href='" + articleUrl + "'>" +
                      "<p class=\"search-result\">" + highlightKeyword(content, slice) +
                      "...</p>" + "</a>";
                  });

                  resultItem += "</li>";
                  resultItems.push({
                    item: resultItem,
                    searchTextCount: searchTextCount,
                    hitCount: hitCount,
                    id: resultItems.length
                  });
                }
              })
            };
            if (keywords.length === 1 && keywords[0] === "") {
              resultContent.innerHTML = '<div id="no-result"><i class="fa fa-search fa-5x" /></div>'
            } else if (resultItems.length === 0) {
              resultContent.innerHTML = '<div id="no-result"><i class="fa fa-frown-o fa-5x" /></div>'
            } else {
              resultItems.sort(function (resultLeft, resultRight) {
                if (resultLeft.searchTextCount !== resultRight.searchTextCount) {
                  return resultRight.searchTextCount - resultLeft.searchTextCount;
                } else if (resultLeft.hitCount !== resultRight.hitCount) {
                  return resultRight.hitCount - resultLeft.hitCount;
                } else {
                  return resultRight.id - resultLeft.id;
                }
              });
              var searchResultList = '<ul class=\"search-result-list\">';
              resultItems.forEach(function (result) {
                searchResultList += result.item;
              })
              searchResultList += "</ul>";
              resultContent.innerHTML = searchResultList;
            }
          }

          if ('auto' === 'auto') {
            input.addEventListener('input', inputEventFunction);
          } else {
            $('.search-icon').click(inputEventFunction);
            input.addEventListener('keypress', function (event) {
              if (event.keyCode === 13) {
                inputEventFunction();
              }
            });
          }

          // remove loading animation
          $(".local-search-pop-overlay").remove();
          $('body').css('overflow', '');

          proceedsearch();
        }
      });
    }

    // handle and trigger popup window;
    $('.popup-trigger').click(function(e) {
      e.stopPropagation();
      if (isfetched === false) {
        searchFunc(path, 'local-search-input', 'local-search-result');
      } else {
        proceedsearch();
      };
    });

    $('.popup-btn-close').click(onPopupClose);
    $('.popup').click(function(e){
      e.stopPropagation();
    });
    $(document).on('keyup', function (event) {
      var shouldDismissSearchPopup = event.which === 27 &&
        $('.search-popup').is(':visible');
      if (shouldDismissSearchPopup) {
        onPopupClose();
      }
    });
  </script>





  

  
  <script src="https://cdn1.lncld.net/static/js/av-core-mini-0.6.1.js"></script>
  <script>AV.initialize("A9MeTkIR49W9kOOSvkggsXge-gzGzoHsz", "HaIEOSDyxpcjwOjRjCYxiWjA");</script>
  <script>
    function showTime(Counter) {
      var query = new AV.Query(Counter);
      var entries = [];
      var $visitors = $(".leancloud_visitors");

      $visitors.each(function () {
        entries.push( $(this).attr("id").trim() );
      });

      query.containedIn('url', entries);
      query.find()
        .done(function (results) {
          var COUNT_CONTAINER_REF = '.leancloud-visitors-count';

          if (results.length === 0) {
            $visitors.find(COUNT_CONTAINER_REF).text(0);
            return;
          }

          for (var i = 0; i < results.length; i++) {
            var item = results[i];
            var url = item.get('url');
            var time = item.get('time');
            var element = document.getElementById(url);

            $(element).find(COUNT_CONTAINER_REF).text(time);
          }
          for(var i = 0; i < entries.length; i++) {
            var url = entries[i];
            var element = document.getElementById(url);
            var countSpan = $(element).find(COUNT_CONTAINER_REF);
            if( countSpan.text() == '') {
              countSpan.text(0);
            }
          }
        })
        .fail(function (object, error) {
          console.log("Error: " + error.code + " " + error.message);
        });
    }

    function addCount(Counter) {
      var $visitors = $(".leancloud_visitors");
      var url = $visitors.attr('id').trim();
      var title = $visitors.attr('data-flag-title').trim();
      var query = new AV.Query(Counter);

      query.equalTo("url", url);
      query.find({
        success: function(results) {
          if (results.length > 0) {
            var counter = results[0];
            counter.fetchWhenSave(true);
            counter.increment("time");
            counter.save(null, {
              success: function(counter) {
                var $element = $(document.getElementById(url));
                $element.find('.leancloud-visitors-count').text(counter.get('time'));
              },
              error: function(counter, error) {
                console.log('Failed to save Visitor num, with error message: ' + error.message);
              }
            });
          } else {
            var newcounter = new Counter();
            /* Set ACL */
            var acl = new AV.ACL();
            acl.setPublicReadAccess(true);
            acl.setPublicWriteAccess(true);
            newcounter.setACL(acl);
            /* End Set ACL */
            newcounter.set("title", title);
            newcounter.set("url", url);
            newcounter.set("time", 1);
            newcounter.save(null, {
              success: function(newcounter) {
                var $element = $(document.getElementById(url));
                $element.find('.leancloud-visitors-count').text(newcounter.get('time'));
              },
              error: function(newcounter, error) {
                console.log('Failed to create');
              }
            });
          }
        },
        error: function(error) {
          console.log('Error:' + error.code + " " + error.message);
        }
      });
    }

    $(function() {
      var Counter = AV.Object.extend("Counter");
      if ($('.leancloud_visitors').length == 1) {
        addCount(Counter);
      } else if ($('.post-title-link').length > 1) {
        showTime(Counter);
      }
    });
  </script>



  
<script>
(function(){
    var bp = document.createElement('script');
    var curProtocol = window.location.protocol.split(':')[0];
    if (curProtocol === 'https') {
        bp.src = 'https://zz.bdstatic.com/linksubmit/push.js';        
    }
    else {
        bp.src = 'http://push.zhanzhang.baidu.com/push.js';
    }
    var s = document.getElementsByTagName("script")[0];
    s.parentNode.insertBefore(bp, s);
})();
</script>


  

  

  

</body>
</html>
